﻿using System;
using System.Text;

namespace InfoJetSoft.Service.Entity
{
	
	
	public class Field
	{
		
		public string JetId
		{
			get
			{
				return jetId;
			}
			
			set
			{
				this.jetId = value;
			}
			
		}
		
		public string Name
		{
			get
			{
				return name;
			}
			
			set
			{
				this.name = value;
			}
			
		}
		
		public string Value
		{
			get
			{
				return value_Renamed;
			}
			
			set
			{
				this.value_Renamed = value;
			}
			
		}

		public bool IsRichText
		{
			get
			{
				return this.isRichText;
			}
			set
			{
				this.isRichText = value;
			}
		}
		
		public int[] Coords
		{
			get
			{
				return coords;
			}
			
			set
			{
				this.coords = value;
			}
			
		}
		
		private string jetId = null;
		private string name = null;
		private string value_Renamed = null;
		private int[] coords = null;
		//CID 0331 //2009.07.22 //Begin
		private bool isRichText = false;
		//CID 0331 //2009.07.22 //End
		
		public Field(string key, string value_Renamed)
		{
			this.jetId = key;
			this.name = key;
			this.value_Renamed = value_Renamed;
		}
		
		public override string ToString()
		{
			StringBuilder buffer = new StringBuilder();
			buffer.Append(this.Name);
			buffer.Append(" ");
			buffer.Append(this.Value);
			if (this.coords != null)
			{
				for (int i = 0; i < this.coords.Length; i++)
				{
					buffer.Append(" " + this.coords[i]);
				}
			}
			return buffer.ToString();
		}
	}
}